/*
 * @(#)UserDaoImpl.java 2013-4-10 ����01:35:11 Order
 */
package com.dingtalk.dingbotmgr.dao.impl;

import java.util.List;

import com.dingtalk.dingbotmgr.dao.AttachmentDao;
import com.dingtalk.dingbotmgr.model.Attachment;
import com.dingtalk.dingbotmgr.model.Project;
import org.springframework.stereotype.Component;

/**
 * UserDaoImpl
 *
 * @author wang
 * @version 1.0
 */
@Component("attachmentDao")
public class AttachmentDaoImpl extends BaseDaoImpl<Attachment> implements AttachmentDao {

    @Override
    public List<Attachment> listByProject(Project project) {
        return list(Attachment.class, "from Attachment a where a.project = ?", new Object[] {project});
    }
}
